"""OA_django URL Configuration

The `urlpatterns` list routes URLs to views. For more information please see:
    https://docs.djangoproject.com/en/3.2/topics/http/urls/
Examples:
Function views
    1. Add an import:  from my_app import views
    2. Add a URL to urlpatterns:  path('', views.home, name='home')
Class-based views
    1. Add an import:  from other_app.views import Home
    2. Add a URL to urlpatterns:  path('', Home.as_view(), name='home')
Including another URLconf
    1. Import the include() function: from django.urls import include, path
    2. Add a URL to urlpatterns:  path('blog/', include('blog.urls'))
"""
from django.contrib import admin
from django.urls import path,include
from .views import *
urlpatterns = [
    path('admin/', admin.site.urls),
    # 菜单查询，增加
    path('menus/',MenuAPIView.as_view()),
    # 菜单修改，删除
    path('menus/<int:id>/',MenuView.as_view()),
    # 登陆日志查询，添加
    path('login-log/',LoginLogAPIView.as_view()),
    # 操作日志查询，添加
    path('act-log/',ActLogAPIView.as_view()),
    # 工资条查询，添加
    path('salary/',SalaryAPIView.as_view()),
    # 工资条上传
    path('salary/uploading/',UploadSalaryAPIView.as_view()),
    # 发送邮箱
    path("addemail/",AddEmailView.as_view()),
    # 编辑邮箱
    path("addemail/<int:id>/",EmailInfoView.as_view()),
    # 添加抄送人
    path("addcopy/",AddCopyView.as_view()),
    # 编辑抄送人
    path("addcopy/<int:id>/",CopyInfoView.as_view()),
]
